import request from '@/utils/request'
// 查询商品类别树数据
export function listGoods(data) {
    return request({
      url: '/tms/goods/category/listGoodsCategoryTree',
      method: 'post',
      params: data,
    })
}
// 查询商品类型
export function goodsType(query){
    return request({
        url: '/tms/goods/category/list',
        method: 'get',
        params: query,
      })
}
// 获取商品类型详细信息
export function goodsDetail(id){
    return request({
        url: '/tms/goods/category/'+id,
        method: 'get',
      })
}
// 新增商品类型
export function goodsAdd(data){
    return request({
        url: '/tms/goods/category',
        method: 'post',
        data:data
      })
}
// 修改商品类型
export function goodsUpdate(data){
  console.log(data);
    return request({
        url: '/tms/goods/category',
        method: 'put',
        data: data
      })
}
// 删除司机信息
export function goodsDel(id) {
    return request({
      url: '/tms/goods/category/' + id,
      method: 'delete'
    })
  }